<script>
export default {
  onLaunch: function () {
    if (!this.isLogin()) {
      return;
    }
    let userInfo = uni.getStorageSync("userInfo");
    if (userInfo) {
      this.$store.commit("setUserInfo", userInfo);
    }
    // 更新加载未读消息数
    uni.setTabBarBadge({
      index: 3,
      text: "3",
    });
    console.log("App Launch");
  },
  onShow: function () {
    console.log("App Show");
  },
  onHide: function () {
    console.log("App Hide");
  },
};
</script>

<style lang="scss">
@import "@/common/styles/common.scss";
</style>
